1. Field of the Invention
The present invention relates to a numerical control system that reduces a delay time when an input signal of an external input/output unit (IO unit) is transferred to a numerical controller that controls machine tools or robots via serial communication.
2. Description of the Related Art
A configuration in which a plurality of IO units is connected between a numerical controller and machine tools or robots (hereinafter, referred to as “numerical control machine tools”) to input/output DI/DO signals (input signals/output signals) is adopted. Then, the numerical controller and the IO units generally exchange DI/DO data at fixed periods. The numerical controller and the IO units exchange DI/DO data at fixed periods, but when there is no exchange of DI/DO data, a signal (idle signal) that repeats toggling in a certain period is input/output.
On the other hand, a specific data pattern is input/output for transmission/reception of DI/DO. Accordingly, idle signals and data patterns representing other DI/DO can be distinguished and the numerical controller determines to which category the received signal belongs (see FIG. 8). As shown in FIG. 8, DI data is transmitted as an aggregate of the start code, header, DI data, footer, CRC, and stop code. Also, DO data is transmitted as an aggregate of the start code, header, DO data, footer, CRC, and stop code.
If a delay time when an input signal into an IO unit is transferred to the numerical controller is reduced, for example, a cycle time of an in-machine measuring function can be reduced.
The in-machine measuring function of a numerical control machine tool in which a touch sensor is mounted on a shaft moving portion of a feed shaft and the touch sensor is brought into contact with an object to be measured by controlling the feed shaft to measure the outside diameter and the like of a work before and after machining by using a signal from the touch sensor during the contact is practically used. The in-machine measuring function measures the object to be measured, based on the timing, which the numerical controller knows, in which the output of the touch sensor changes from OFF to ON when the touch sensor is brought into contact with the object to be measured (work) after the feed shaft is moved.
In addition, a configuration in which a plurality of IO units is connected between the numerical controller and machine tools to input/output DI/DO signals is adopted. If the touch sensor output is input into the IO unit in a numerical control machine tool configured as described above, compared with a case when input into the interface of the DI signal provided in the numerical controller, the configuration/wiring can be designed more freely.
The above technology is disclosed by JP 2013-196307 A. The technology disclosed by JP 2013-196307 A provides a numerical control system capable of making more precise in-machine measurements by making time measurements by IO units.
As similar technologies, JP 05-66820 A discloses a method of event-driven communication being performed by an IO unit with a numerical controller by input of a DI signal as a trigger to prevent an increase of the delay time and JP 06-149320 A discloses a method of synchronizing timers, each of which is held by each IO unit, counting an internal timer by a communication protocol.
However, the numerical controller and the IO unit exchange DI/DO data only periodically and thus, according to the method of JP 2013-196307 A, the delay time between input of the touch sensor output and the detection of input of the touch sensor output into the IO unit by the numerical controller may increase. If the delay time increases, the time between an in-machine measuring operation and the next operation increases, leading to an increased cycle time.
If the technology disclosed by JP 05-66820 A or JP 06-14932 A is used, an increased delay time can be prevented, but according to the above method, an arbitration circuit for data transmission is needed and the circuit scale is increased, which is disadvantageous for IO units from which the cost reduction is strictly demanded.